package HttpUtils;

import android.content.Context;

import http.HttpBodyBase;

/**
 * Created by Administrator on 2016/3/19.
 */
public class HttpCommunityRequest extends HttpBodyBase {
    public HttpCommunityRequest(Context context, int type) {
        super(context);
        switch (type) {
            case 0:
                //搜索小区
                setAction("/index.php/Home/CarPark/search_community");
                break;
            case 1:
                setAction("/index.php/Home/Area/area_list");
        }
    }

    public void search(String keyword, long area_id) {
        if (area_id != 0) {
            params.put("area_id", area_id);
        }
        params.put("keyword", keyword);
    }
}
